Optimal. Leaf size=74 \[ \frac {3 a \tanh ^{-1}(\sin (c+d x))}{8 d}+\frac {b \sec ^5(c+d x)}{5 d}+\frac {3 a \sec (c+d x) \tan (c+d x)}{8 d}+\frac {a \sec ^3(c+d x) \tan (c+d x)}{4 d} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.06, antiderivative size = 74, normalized size of antiderivative = 1.00, number of steps
used = 7, number of rules used = 5, integrand size = 26, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.192, Rules used = {3169, 3853,
3855, 2686, 30} \begin {gather*} \frac {3 a \tanh ^{-1}(\sin (c+d x))}{8 d}+\frac {a \tan (c+d x) \sec ^3(c+d x)}{4 d}+\frac {3 a \tan (c+d x) \sec (c+d x)}{8 d}+\frac {b \sec ^5(c+d x)}{5 d} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 30
Rule 2686
Rule 3169
Rule 3853
Rule 3855
Rubi steps
\begin {align*} \int \sec ^6(c+d x) (a \cos (c+d x)+b \sin (c+d x)) \, dx &=\int \left (a \sec ^5(c+d x)+b \sec ^5(c+d x) \tan (c+d x)\right ) \, dx\\ &=a \int \sec ^5(c+d x) \, dx+b \int \sec ^5(c+d x) \tan (c+d x) \, dx\\ &=\frac {a \sec ^3(c+d x) \tan (c+d x)}{4 d}+\frac {1}{4} (3 a) \int \sec ^3(c+d x) \, dx+\frac {b \text {Subst}\left (\int x^4 \, dx,x,\sec (c+d x)\right )}{d}\\ &=\frac {b \sec ^5(c+d x)}{5 d}+\frac {3 a \sec (c+d x) \tan (c+d x)}{8 d}+\frac {a \sec ^3(c+d x) \tan (c+d x)}{4 d}+\frac {1}{8} (3 a) \int \sec (c+d x) \, dx\\ &=\frac {3 a \tanh ^{-1}(\sin (c+d x))}{8 d}+\frac {b \sec ^5(c+d x)}{5 d}+\frac {3 a \sec (c+d x) \tan (c+d x)}{8 d}+\frac {a \sec ^3(c+d x) \tan (c+d x)}{4 d}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.24, size = 68, normalized size = 0.92 \begin {gather*} \frac {b \sec ^5(c+d x)}{5 d}+\frac {a \sec ^3(c+d x) \tan (c+d x)}{4 d}+\frac {3 a \left (\tanh ^{-1}(\sin (c+d x))+\sec (c+d x) \tan (c+d x)\right )}{8 d} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.29, size = 63, normalized size = 0.85
method | result | size |
derivativedivides | \(\frac {a \left (-\left (-\frac {\left (\sec ^{3}\left (d x +c \right )\right )}{4}-\frac {3 \sec \left (d x +c \right )}{8}\right ) \tan \left (d x +c \right )+\frac {3 \ln \left (\sec \left (d x +c \right )+\tan \left (d x +c \right )\right )}{8}\right )+\frac {b}{5 \cos \left (d x +c \right )^{5}}}{d}\) | \(63\) |
default | \(\frac {a \left (-\left (-\frac {\left (\sec ^{3}\left (d x +c \right )\right )}{4}-\frac {3 \sec \left (d x +c \right )}{8}\right ) \tan \left (d x +c \right )+\frac {3 \ln \left (\sec \left (d x +c \right )+\tan \left (d x +c \right )\right )}{8}\right )+\frac {b}{5 \cos \left (d x +c \right )^{5}}}{d}\) | \(63\) |
risch | \(\frac {-15 i a \,{\mathrm e}^{9 i \left (d x +c \right )}-70 i a \,{\mathrm e}^{7 i \left (d x +c \right )}+128 b \,{\mathrm e}^{5 i \left (d x +c \right )}+70 i a \,{\mathrm e}^{3 i \left (d x +c \right )}+15 i a \,{\mathrm e}^{i \left (d x +c \right )}}{20 d \left ({\mathrm e}^{2 i \left (d x +c \right )}+1\right )^{5}}-\frac {3 a \ln \left ({\mathrm e}^{i \left (d x +c \right )}-i\right )}{8 d}+\frac {3 a \ln \left ({\mathrm e}^{i \left (d x +c \right )}+i\right )}{8 d}\) | \(123\) |
norman | \(\frac {-\frac {2 b}{5 d}-\frac {5 a \tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{4 d}-\frac {3 a \left (\tan ^{3}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{4 d}+\frac {a \left (\tan ^{5}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{2 d}-\frac {a \left (\tan ^{7}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{2 d}+\frac {3 a \left (\tan ^{9}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{4 d}+\frac {5 a \left (\tan ^{11}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{4 d}-\frac {4 b \left (\tan ^{6}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{d}-\frac {2 b \left (\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{5 d}-\frac {2 b \left (\tan ^{8}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{d}-\frac {2 b \left (\tan ^{10}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{d}-\frac {4 b \left (\tan ^{4}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{d}}{\left (\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )-1\right )^{5} \left (1+\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}-\frac {3 a \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )-1\right )}{8 d}+\frac {3 a \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )+1\right )}{8 d}\) | \(261\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.28, size = 86, normalized size = 1.16 \begin {gather*} -\frac {5 \, a {\left (\frac {2 \, {\left (3 \, \sin \left (d x + c\right )^{3} - 5 \, \sin \left (d x + c\right )\right )}}{\sin \left (d x + c\right )^{4} - 2 \, \sin \left (d x + c\right )^{2} + 1} - 3 \, \log \left (\sin \left (d x + c\right ) + 1\right ) + 3 \, \log \left (\sin \left (d x + c\right ) - 1\right )\right )} - \frac {16 \, b}{\cos \left (d x + c\right )^{5}}}{80 \, d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 2.32, size = 88, normalized size = 1.19 \begin {gather*} \frac {15 \, a \cos \left (d x + c\right )^{5} \log \left (\sin \left (d x + c\right ) + 1\right ) - 15 \, a \cos \left (d x + c\right )^{5} \log \left (-\sin \left (d x + c\right ) + 1\right ) + 10 \, {\left (3 \, a \cos \left (d x + c\right )^{3} + 2 \, a \cos \left (d x + c\right )\right )} \sin \left (d x + c\right ) + 16 \, b}{80 \, d \cos \left (d x + c\right )^{5}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F(-1)] Timed out
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Timed out} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [B] Leaf count of result is larger than twice the leaf count of optimal. 141 vs.
\(2 (66) = 132\).
time = 0.45, size = 141, normalized size = 1.91 \begin {gather*} \frac {15 \, a \log \left ({\left | \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) + 1 \right |}\right ) - 15 \, a \log \left ({\left | \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) - 1 \right |}\right ) + \frac {2 \, {\left (25 \, a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{9} - 40 \, b \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{8} - 10 \, a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{7} - 80 \, b \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{4} + 10 \, a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} - 25 \, a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) - 8 \, b\right )}}{{\left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - 1\right )}^{5}}}{40 \, d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 4.12, size = 175, normalized size = 2.36 \begin {gather*} \frac {3\,a\,\mathrm {atanh}\left (\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\right )}{4\,d}-\frac {-\frac {5\,a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^9}{4}+2\,b\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^8+\frac {a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^7}{2}+4\,b\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^4-\frac {a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^3}{2}+\frac {5\,a\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}{4}+\frac {2\,b}{5}}{d\,\left ({\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^{10}-5\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^8+10\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^6-10\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^4+5\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2-1\right )} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________